From: Richard M. Stallman Date: Mon, 1 Mar 1993 08:55:35 +0000 (+0000) Subject: (del_range): Update point before offset_intervals. X-Git-Tag: archive/raspbian/1%29.2+1-2+rpi1^2~5^2~97097 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:///%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:/?a=commitdiff_plain;h=16032db6875c2840f8b51f86ccb1658940795910;p=emacs.git (del_range): Update point before offset_intervals. --- diff --git a/src/insdel.c b/src/insdel.c index 7f25a967d46..35345440c2a 100644 --- a/src/insdel.c +++ b/src/insdel.c @@ -444,9 +444,6 @@ del_range (from, to) record_delete (from, numdel); MODIFF++; - /* Only defined if Emacs is compiled with USE_TEXT_PROPERTIES */ - offset_intervals (current_buffer, point, - numdel); - /* Relocate point as if it were a marker. */ if (from < point) { @@ -456,6 +453,9 @@ del_range (from, to) SET_PT (point - numdel); } + /* Only defined if Emacs is compiled with USE_TEXT_PROPERTIES */ + offset_intervals (current_buffer, point, - numdel); + /* Relocate all markers pointing into the new, larger gap to point at the end of the text before the gap. */ adjust_markers (to + GAP_SIZE, to + GAP_SIZE, - numdel - GAP_SIZE);